using System;

namespace Microsoft.SqlServer.Management.SqlManagerUI
{
	public class DatabaseEntity : ICloneable
	{
		private bool _isDefault;

		private string _databaseName = string.Empty;

		private string _serverName = string.Empty;

		private string _username = string.Empty;

		private string _password = string.Empty;

		private bool _savePassword;

		public string DatabaseName
		{
			get
			{
				return this._databaseName;
			}
			set
			{
				this._databaseName = value;
			}
		}

		public string FullName
		{
			get
			{
				return this.ServerName + "." + this.DatabaseName;
			}
		}

		public string ServerName
		{
			get
			{
				return this._serverName;
			}
			set
			{
				this._serverName = value;
			}
		}

		public string UserName
		{
			get
			{
				return this._username;
			}
			set
			{
				this._username = value;
			}
		}

		public bool SavePassword
		{
			get
			{
				return this._savePassword;
			}
			set
			{
				this._savePassword = value;
			}
		}

		public string Password
		{
			get
			{
				return this._password;
			}
			set
			{
				this._password = value;
			}
		}

		public bool IsDefault
		{
			get
			{
				return this._isDefault;
			}
			set
			{
				this._isDefault = value;
			}
		}

		public object Clone()
		{
			return new DatabaseEntity
			{
				DatabaseName = this.DatabaseName,
				ServerName = this.ServerName,
				UserName = this.UserName,
				Password = this.Password,
				IsDefault = this.IsDefault,
				SavePassword = this.SavePassword
			};
		}
	}
}
